﻿#include "FITKAbaqusHDF5AdaptorConnectorBehavior.h"
#include "FITK_Kernel/FITKCore/FITKEnumTransformer.hpp"
#include "FITK_Interface/FITKInterfaceIO/FITKAbstractHDF5Reader.h"
#include "FITK_Interface/FITKInterfaceIO/FITKAbstractHDF5Writer.h"
#include "FITK_Interface/FITKInterfaceStructural/FITKAbaConnectorAssignment.h"
#include "FITK_Interface/FITKInterfaceStructural/FITKAbaConnectorBehavior.h"

namespace IO
{
    QString FITKAbaqusHDF5AdaptorConnectorBehavior::getAdaptorClass()
    {
        return "FITKAbaqusHDF5AdaptorConnectorBehavior";
    }

    bool FITKAbaqusHDF5AdaptorConnectorBehavior::adaptR()
    {
        auto cb = dynamic_cast<Interface::FITKAbaConnectorBehavior*>(_dataObj);
        if (!_reader || !cb || !_h5Group) return false;
        bool isR = true;
        isR &= readConnectorAssignment(cb, *_h5Group);
        return isR;
    }

    bool FITKAbaqusHDF5AdaptorConnectorBehavior::adaptW()
    {
        auto cb = dynamic_cast<Interface::FITKAbaConnectorBehavior*>(_dataObj);
        if (!_writer || !cb || !_h5Group) return false;
        bool isW = true;
        isW &= writeConnectorAssignment(cb, *_h5Group);
        return isW;
    }

    bool FITKAbaqusHDF5AdaptorConnectorBehavior::readConnectorAssignment(Interface::FITKAbaConnectorBehavior * connectorBehavior, H5::Group & h5Group)
    {
        return false;
    }

    bool FITKAbaqusHDF5AdaptorConnectorBehavior::writeConnectorAssignment(Interface::FITKAbaConnectorBehavior * connectorBehavior, H5::Group & h5Group)
    {
        return false;
    }

    bool FITKAbaqusHDF5AdaptorConnectorBehavior::readBehaviorElasticity(Interface::FITKAbaConnectorBehavior * connectorBehavior, H5::Group & h5Group)
    {

        return false;
    }

    bool FITKAbaqusHDF5AdaptorConnectorBehavior::writeBehaviorElasticity(Interface::FITKAbaConnectorBehavior * connectorBehavior, H5::Group & h5Group)
    {
        return false;
    }
    bool FITKAbaqusHDF5AdaptorConnectorBehavior::readBehaviorDamping(Interface::FITKAbaConnectorBehavior * connectorBehavior, H5::Group & h5Group)
    {
        return false;
    }
    bool FITKAbaqusHDF5AdaptorConnectorBehavior::writeBehaviorDamping(Interface::FITKAbaConnectorBehavior * connectorBehavior, H5::Group & h5Group)
    {
        return false;
    }
}


